CREATE TABLE [dbo].[TRBANC_EXTO]
(
[CO_EMPR] [dbo].[TD_VC_002] NOT NULL,
[CO_BANC] [dbo].[TD_VC_003] NOT NULL,
[NU_CNTA_BANC] [dbo].[TD_VC_020] NOT NULL,
[AA_BNCO] [dbo].[TD_VC_004] NOT NULL,
[MM_BNCO] [dbo].[TD_VC_002] NOT NULL,
[TI_MOVI_BANC] [dbo].[TD_VC_001] NOT NULL,
[NU_COMP_BANC] [dbo].[TD_VC_008] NOT NULL,
[TI_MOVI_EXTO] [dbo].[TD_VC_001] NOT NULL,
[CO_TIPO_OPER] [dbo].[TD_VC_003] NULL,
[NU_COMP_EXTO] [dbo].[TD_VC_008] NOT NULL,
[FE_ANUL] [dbo].[TD_DT_001] NOT NULL,
[CO_USUA_CREA] [dbo].[TD_VC_008_USUA] NULL CONSTRAINT [DF__TRBANC_EX__CO_US__46535886] DEFAULT (suser_sname()),
[FE_USUA_CREA] [dbo].[TD_DT_001_SIST] NULL CONSTRAINT [DF__TRBANC_EX__FE_US__47477CBF] DEFAULT (getdate()),
[CO_USUA_MODI] [dbo].[TD_VC_008_USUA] NULL CONSTRAINT [DF__TRBANC_EX__CO_US__483BA0F8] DEFAULT (suser_sname()),
[FE_USUA_MODI] [dbo].[TD_DT_001_SIST] NULL CONSTRAINT [DF__TRBANC_EX__FE_US__492FC531] DEFAULT (getdate())
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[TRBANC_EXTO] ADD CONSTRAINT [PK__TRBANC_E__8AA9A0290055DCE9] PRIMARY KEY CLUSTERED  ([CO_EMPR], [CO_BANC], [NU_CNTA_BANC], [AA_BNCO], [MM_BNCO], [TI_MOVI_BANC], [NU_COMP_BANC]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[TRBANC_EXTO] ADD CONSTRAINT [FK__TRBANC_EX__CO_EM__1A35AA7D] FOREIGN KEY ([CO_EMPR]) REFERENCES [dbo].[TMPARA_TESO] ([CO_EMPR])
GO
